import request  from '../utils/request'
// 查询融资意向
export function selectIntention() {
    return request({
        method: 'get',
        url: '/finance/selectIntentionByName',
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
  }
// 添加融资意向
export function insertIntention(params) {
    return request({
        method: 'post',
        url: '/finance/insertIntentionByName',
        data:params,
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
  }
// 修改融资意向
export function updateIntention(params) {
    return request({
        method: 'put',
        url: '/finance/updateIntentionByName',
        data:params,
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
  }
// 删除融资意向
export function deleteIntention() {
    return request({
        method: 'delete',
        url: '/finance/deleteIntentionByName',
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
  }
// 查询推荐人
export function selectRecommned() {
    return request({
        method: 'get',
        url: '/finance/selectRecommendByName',
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
  }


  // 增加单人贷款
export function addFinance(params) {
    return request({
        method: 'post',
        url: '/finance/add',
        data:params,
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
}
// 增加组合贷款
export function addFinanceMulti(params) {
    return request({
        method: 'post',
        url: '/finance/addFinanceMulti',
        data:params,
        headers: {
            'Authorization': window.localStorage.token,
        },
    })
}
// 银行查询接口
export function selectBank(params) {
 return request({
     method: 'get',
     url: '/finance/selectBank',
     headers: {
         'Authorization': window.localStorage.token,
     },
  })
}
//根据id
// @GetMapping("/selectById/{bankId}")
export function selectFinaceUser(bankId) {
    return request({
        method: 'get',
        url: '/finance/selectBankById/'+bankId,
        headers: {
            'Authorization': window.localStorage.token,
        },
     })
   }